using System;
using System.Collections.Generic;
using System.Text;
using System.Xml.Serialization;

namespace ClientTools.Client.Controls.Packager.PackageClasses
{
    public class Macro
    {
        private string _name;

        [XmlElement("name")]
        public string Name
        {
            get { return _name; }
            set { _name = value; }
        }

        private string _alias;

        [XmlElement("alias")]
        public string Alias
        {
            get { return _alias; }
            set { _alias = value; }
        }

        private string _scriptType;

        [XmlElement("scriptType")]
        public string ScriptType
        {
            get { return _scriptType; }
            set { _scriptType = value; }
        }

        private string _scriptAssembly;

        [XmlElement("scriptAssembly")]
        public string ScriptAssembly
        {
            get { return _scriptAssembly; }
            set { _scriptAssembly = value; }
        }

        private string _xslt;

        [XmlElement("xslt")]
        public string Xslt
        {
            get { return _xslt; }
            set { _xslt = value; }
        }

        private bool _useInEditor;

        [XmlElement("useInEditor")]
        public bool UseInEditor
        {
            get { return _useInEditor; }
            set { _useInEditor = value; }
        }

        private int _refreshRate;

        [XmlElement("refreshRate")]
        public int RefreshRate
        {
            get { return _refreshRate; }
            set { _refreshRate = value; }
        }

        private PackageClasses.MacroPropertyCollection _propertyCollection = new MacroPropertyCollection();

        [XmlArray("properties")]
        [XmlArrayItem("property")]
        public PackageClasses.MacroPropertyCollection Properties
        {
            get { return _propertyCollection; }
            set { _propertyCollection = value; }
        }

    }
}
